const KEY = "hkzf_token"

// 储存token
const setToken = token => {
    localStorage.setItem(KEY, token)
}
// 获取token
const getToken = () => {
    return localStorage.getItem(KEY)
}
// 删除token
const removeToken = () => {
    localStorage.removeItem(KEY)
}
// 判断是否有token
const isAuth = () => {
    return getToken() != null ? true : false
}
export { setToken, getToken, removeToken, isAuth }